import os
import shutil

# 删除当前路径下所有以 "Backup" 开头的文件夹
for root, dirs, files in os.walk(".", topdown=False):
    for name in dirs:
        if name.startswith("./Backup"):
            shutil.rmtree(os.path.join(root, name))

print("Backup folders and their contents have been deleted.")